@(vehicules: List[Vehicule], vehiculeForm: Form[Vehicule])

@import helper._

@main("Catalogue de vehicules") {
    
    <h1>@vehicules.size() vehicule(s)</h1>
    
    <ul>
        @for(vehicule <- vehicules) {
            <li>
                @vehicule.libelle
                
                @form(routes.Application.deleteVehicule(vehicule.id)) {
                    <input type="submit" value="Delete">
                }
            </li>
        }
    </ul>
    
    <h2>Ajouter un nouveau vehicule</h2>
    
    @form(routes.Application.newVehicule()) {
        
        @inputText(vehiculeForm("libelle")) 
        
        <input type="submit" value="Creer">
        
    }
    
}